package com.centaline.androidsalesblog.api.usercenter;

import com.centaline.androidsalesblog.api.UserCenterApi;
import com.centaline.androidsalesblog.constants.AppConstant;
import com.centaline.androidsalesblog.model.responseobject.CollectInfoListRo;
import com.centanet.framework.interfaces.IResponseListener;

/**
 * 房源收藏信息列表
 * Created by ruanzb on 2016/3/18.
 */
public class CollectInfoListApi extends UserCenterApi<CollectInfoListRo> {

    private int Count = 10;
    private int FirstIndex;
    private String collectValue;
    private String collectUrl;

    public CollectInfoListApi(Class<?> tag, Class<CollectInfoListRo> aClass,
                              IResponseListener<CollectInfoListRo> iResponseListener) {
        super(tag, aClass, iResponseListener);
    }


    public void setCount(int count) {
        Count = count;
    }

    public void setFirstIndex(int firstIndex) {
        FirstIndex = firstIndex;
    }

    public void setCollectValue(String collectValue) {
        this.collectValue = collectValue;
    }

    public void setCollectUrl(String collectUrl) {
        this.collectUrl = collectUrl;
    }

    @Override
    protected void setParams() {
        putParams("Count", Count);
        putParams("FirstIndex", FirstIndex);
        putParams("UserId", AppConstant.UserId);
        putParams("CityCode", AppConstant.CityCode);
        putParams("IsDel", 0);
        if (sourceType != null) {
            putParams("Source", sourceType.getSource());
        }
        putStringParams("CollectValue", collectValue);
        putStringParams("collectUrl", collectUrl);
    }

    @Override
    protected String getPath() {
        return "CollectInfoListRequest";
    }
}
